'use strict';

var arduinoDirectives = angular.module('arduinoDirectives', []);

arduinoDirectives.directive('tabArduinos', function(listeArduinos) {
    return {
        template: "<div class='well well-large'>ip : {{ip}} / description : {{desc}}</div>"
    };
});


arduinoDirectives.directive('successCallbackDirective', function() {
    return{
        restrict: 'E',
        template: "<div class='glyphicon glyphicon-ok text-success'> Réponse :</div>"
    }
});
arduinoDirectives.directive('errorCallbackDirective', function() {
    return{
        restrict: 'E',
        scope: {
            info: '=info'
        },
        template: "<div class='glyphicon glyphicon-remove text-danger'> Echec <br> {{info}}</div>"
    }
});
arduinoDirectives.directive('warningCallbackDirective', function() {
    return{
        restrict: 'E',
        scope: {
            info: '=info'
        },
        template: "<div class='glyphicon glyphicon-warning-sign text-warning'> Warning: {{info}}</div>"
    }
});

  